import { createApp } from 'vue';

import App from './App.vue';
import router from './router/index'
import ElementPlus from 'element-plus';
//import 'element-plus/lib/theme-chalk/index.css';
import 'element-plus/dist/index.css'
import VueCookies from "vue-cookies";
//1.引入cookie依赖
// cnpm install vue-session/vue-cookies --save
//2.给main.js配置使用：

//设置路由
const app = createApp(App).use(router)
//基础url 设为全局变量
app.provide('$baseURL', '/apis')  //http://192.168.123.187:8090  //https://hk23790725.zicp.fun http://192.168.31.59:8090 http://localhost:8090  http://192.168.123.187:8080/  http://192.168.31.59:8080/ q2x3790725.zicp.vip:28219

/**
 * localhost和127.0.0.1并不能共享cookie，我这个跳转前后者都有，导致需要重复登录。
 * 此外localhost不经过网卡，127.0.0.1经过网卡
 * */
app.provide('$vueURL', 'http://localhost:8777')   //http://192.168.31.60:8080 // http://192.168 .123.187:8080  http://192.168.31.59:8090  hk23790725.zicp.fun:47545 http://192.168.123.187:8080

app.use(ElementPlus)
//app.use(VueCookies)
app.config.globalProperties.$cookies = VueCookies
app.mount('#app')


